<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <title></title>
    <th:block th:include="statics/common/page/header"></th:block>
</head>
<body>
<div id="workflowCurrent" v-cloak>
	<div v-show="showList">
        <Row class="search-panel-space">
            <div class="search-group">
                <i-col span="5">
                	<label class="search-label-20">名称:</label>
                    <i-input v-model="q.businessName" @on-enter="query" placeholder="名称" class="search-item-width-75"/>
                </i-col>
                <i-button @click="query">查询</i-button>
                <i-button @click="reloadSearch">重置</i-button>
            </div>
        </Row>    
        <Row :gutter="16">
            <div class="buttons-group">
                <i-button type="warning" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;审核</i-button>
            </div>
        </Row>
	    <table id="workflowCurrentGrid"></table>
    </div>

    <Card v-show="!showList">
        <p slot="title">{{title}}</p>
		<i-form ref="formValidate" :model="workflowCurrent" :rules="ruleValidate" :label-width="80">
            <Form-item label="所属流程" prop="workflowName">{{workflowCurrent.workflowName}}</Form-item>
            <Form-item label="所属业务" prop="businessName">{{workflowCurrent.businessName}}</Form-item>
            <Form-item label="审核结果" prop="audit">
            	<Radio-group v-model="workflowCurrent.audit">
                    <Radio label="2">
                        <span>通过</span>
                    </Radio>
                    <Radio label="3">
                        <span>不通过</span>
                    </Radio>
                </Radio-group>
            </Form-item>
            <Form-item label="原因" prop="reason">
                <i-input v-model="workflowCurrent.reason" placeholder="原因"/>
            </Form-item>
            <Form-item>
                <i-button type="primary" @click="handleSubmit('formValidate')">提交</i-button>
                <i-button type="warning" @click="reload" style="margin-left: 8px"/>返回</i-button>
                <i-button type="ghost" @click="handleReset('formValidate')" style="margin-left: 8px">重置</i-button>
            </Form-item>
        </i-form>
	</Card>
</div>

<script th:src="@{../statics/js/workflow/workflowcurrent.js}"></script>
</body>
</html>